<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>全角字符转换工具</title>
    <link rel="stylesheet" href="qjzh.css">
    <link rel="shortcut icon" href="../favicon.png" type="image/png">
    <script>
        const savedTheme = localStorage.getItem('theme') || 'light';
        document.documentElement.setAttribute('data-theme', savedTheme);
        window.addEventListener('storage', (e) => {
            if (e.key === 'theme') {
                document.documentElement.setAttribute('data-theme', e.newValue || 'light');
            }
        });
    </script>
</head>
<body>
    <div class="container">
        <header>
            <h1>全角字符转换工具</h1>
        </header>
        
        <main class="converter">
            <div class="input-area">
                <label for="inputText">输入文本：</label>
                <textarea id="inputText" placeholder="请在此输入需要转换的文本..."></textarea>
            </div>
            
            <div class="controls">
                <button id="toFullWidth">转换</button>
                <button id="clearText">清空</button>
                <button id="copyText">复制</button>
                <button id="toggleTheme" class="theme-toggle">返回</button>
            </div>
            <div id="message" class="message"></div>
            
            <div class="output-area">
                <label for="outputText">转换结果：</label>
                <textarea id="outputText" readonly placeholder="转换后的结果将显示在这里..."></textarea>
            </div>
        </main>
        
        <footer>
            <p>所有内容由用户输入，与本站无关</p>
        </footer>
    </div>
    
    <script src="qjzh.js"></script>
</body>
</html>